//
//  test.m
//  XinLang_OC
//
//  Created by WONG on 16/3/18.
//  Copyright © 2016年 cheuhui. All rights reserved.
//

#import "test.h"

@implementation test

+ (instancetype)sharedHttpTool {
    static id instance = nil;
    static dispatch_once_t onceToken;
    dispatch_once(&onceToken, ^{
        instance = [[self alloc] init];
    });
    return instance;
}

+ (instancetype)allocWithZone:(struct _NSZone *)zone {
    static id instance = nil;
    static dispatch_once_t onceToken;
    dispatch_once(&onceToken, ^{
        instance = [super allocWithZone:zone];
    });
    return instance;
}

+ (instancetype)sharedSyns {
    static id synInstance;
    @synchronized(self) {
        if (synInstance == nil) {
            synInstance = [[self alloc] init];
        }
    }
    return synInstance;
}




@end





